import reducer from './reduces/index.js';
import { createStore, applyMiddleware } from 'redux';
import thunk from 'redux-thunk';
import logger from 'redux-logger';
export function getClientStore() { // 创建仓库
  let initState = window.context.state; // 拿到服务端的状态

  return createStore(reducer, initState, applyMiddleware(thunk, logger));
}

export function getServerStore() { // 创建仓库
  return createStore(reducer, applyMiddleware(thunk, logger));
}